//
//	_MiscMergeDateCommand.m -- "date" merge command implementation
//		Written by Don Yacktman Copyright (c) 1995 by Don Yacktman.
//				Version 1.0.  All rights reserved.
//		This notice may not be removed from this source code.
//
//	This object is included in the MiscKit by permission from the author
//	and its use is governed by the MiscKit license, found in the file
//	"LICENSE.rtf" in the MiscKit distribution.  Please refer to that file
//	for a list of all applicable permissions and restrictions.
//	

#import <misckit/miscmerge.h>
#import "_MiscMergeDateCommand.h"

@implementation _MiscMergeDateCommand

// ***** This should be localized
static char *monthString[12] = {
		"January", "February", "March",
		"April", "May", "June",
		"July", "August", "September",
		"October", "November", "December" };

- parseFromString:(MiscString *)aString
{
	return self;
}


- executeForMerge:(MiscMergeEngine *)aMerger
{ // ***** need to deal with other format strings
	MiscString *tempString = [MiscString new];
	MiscTime *theTime = [[MiscTime alloc] initWithCurrentTime];
	[tempString setFromFormat:"%s %d, %d", monthString[[theTime month]],
			([theTime day] + 1), [theTime year]];
	[aMerger appendToOutput:tempString];
	[tempString free];
	[theTime free];
	return self;
}

@end


